﻿Public Class clsUser
    Public Function getUserListByCJ(workshop_id As Integer) As DataTable
        Dim szSql As String = "select * from sf.t_user where partment = ? and user_enabled = true order by user_id "
        Return DBacs.ExecuteSql(szSql, -1, workshop_id)
    End Function

    Public Function getUserListByCJ(workshop_id As String, bz_details As String) As DataTable
        Dim szSql As String
        If bz_details.Equals("1") = False Then
            szSql = "select * from sf.t_user where 1=1 and partment in (" & workshop_id & ") and classes_details = " & bz_details & " and user_enabled = true "
        Else
            szSql = "select * from sf.t_user where 1=1 and partment = " & workshop_id & " and classes <> " & bz_details & " and user_enabled = true "
        End If
        Return DBacs.ExecuteSql(szSql, -1)
    End Function

End Class
